package com.spic.system.api;

import com.spic.common.core.constant.SecurityConstants;
import com.spic.common.core.constant.ServiceNameConstants;
import com.spic.common.core.web.domain.AjaxResult;
import com.spic.common.feign.FeignRequestInterceptor;
import com.spic.system.api.dto.BlastDto;
import com.spic.system.api.factory.RemoteBlastDeploymentFallbackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestHeader;

/**
 * RemoteBlastDeploymentService
 *
 * @author xuxiaochang@chinasofi.com
 * @date 2022/3/22
 */
@FeignClient(contextId = "RemoteBlastDeploymentService", value = ServiceNameConstants.SPIC_BUSINESS_TICKETS, configuration = FeignRequestInterceptor.class, fallbackFactory = RemoteBlastDeploymentFallbackFactory.class)
public interface RemoteBlastDeploymentService {
    @PostMapping("/blast/holes")
    AjaxResult holes(@RequestBody BlastDto blastDto, @RequestHeader(SecurityConstants.FROM_SOURCE) String source);
}
